import { defineConfig } from 'umi/lib/defineConfig';
import { routes } from './routes';
import defaultSettings from './default-settings';
import chainWebpack from './webpack';
import proxy from './proxy';

export default defineConfig({
  hash: true,
  routes,
  targets: {
    ie: 11,
  },
  chainWebpack,
  nodeModulesTransform: {
    type: 'none',
  },
  // layout: {
  //   name: defaultSettings.title,
  //   locale: false,
  //   layout: 'side'
  // },
  theme: {
    'primary-color': defaultSettings.primaryColor,
    //  'text-color': 'red',
    //  'modal-header-bg': 'red',
    //  'card-background': 'rgba(0,0,0,0.60)',
    // 'card-head-background':'rgba(0,0,0,0.60)'
  },
  // 初始化时,会出现"export 'SelectLang' was not found in 'umi'的警告，配置以下即可
  locale: {
    default: 'zh-CN',
    antd: false,
    title: false,
    // baseNavigator: true,
    // baseSeparator: '-',
  },
  proxy: proxy,
  antd: {},
  outputPath: 'test',
});
